SequenceEqual(TSource) Method (ParallelQuery(TSource), ParallelQuery(TSource))

Task Parallel System.Threading

Determines whether two parallel sequences are equal by comparing the elements by using the default equality comparer for their type.

Namespace:  System.Linq
Assembly:  System.Threading (in System.Threading.dll)

Syntax

Visual Basic (Declaration)
Public Shared Function SequenceEqual(Of TSource) ( _
	first As ParallelQuery(Of TSource), _
	second As ParallelQuery(Of TSource) _
) As Boolean
C#
public static bool SequenceEqual<TSource>(
	ParallelQuery<TSource> first,
	ParallelQuery<TSource> second
)

Parameters

first
Type: System.Linq..::.ParallelQuery<(Of <(TSource>)>)
A sequence to compare to second.
second
Type: System.Linq..::.ParallelQuery<(Of <(TSource>)>)
A sequence to compare to the first input sequence.

Type Parameters

TSource
The type of the elements of the input sequences.

Return Value

true if the two source sequences are of equal length and their corresponding elements are equal according to the default equality comparer for their type; otherwise, false.

Exceptions

ExceptionCondition
System..::.ArgumentNullException first or second is a null reference (Nothing in Visual Basic).
System..::.AggregateException One or more exceptions occurred during the evaluation of the query.
System..::.OperationCanceledException The query was canceled.

See Also